<?php
/* @var $this MainController */

?>
<h2>CSV scanner</h2>
<?php if(isset($message)):?>
<span style="color: red"><?php echo $message; ?></span>
<?php endif;?>     
<?php echo CHtml::beginForm('/main/upload','post',array('enctype'=>'multipart/form-data'));?>
<table id="upload_form">

<tr>
    <td>Site Name:</td><td><?php echo CHtml::textField('site_name','',array('placeholder'=>'http://site.com'));?><br /></td>
</tr>
<tr>
    <td>Site CSV:</td><td><?php echo CHtml::fileField('xml_file');?></td>
<tr>
    <td></td><td><span id="file_name_message"></span></td>
</tr>
</tr>
    <td></td><td><?php echo CHtml::submitButton('Download')?></td>
</td>

</table>
<?php echo CHtml::endForm();?>
<?php if(isset($show_results)): 
    echo $show_results; ?><br />
    <center><a href="#" id="downloadPage">SAVE RESULTS</a></center>
<?php endif;?>